package com.szc.demo01.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.szc.demo01.pojo.Office;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

import java.util.List;

/**
 * @Author: WeiXin
 * @Date: 2021/01/14 7:53:30
 */
public interface OfficeMapper extends BaseMapper<Office>{
    /**
     * 根据报销人查询
     * @param eId
     * @return
     */
    @Select("select off_id,item_name,item_price,item_count,item_Totalprice,purchase,e_Id,is_Bx from office where e_Id=#{eId}")
    public List<Office> listByeId(long eId);

    @Select("select off_id,item_name,item_price,item_count,item_totalprice,purchase,e_Id,is_bx from office where e_id=#{eId} and is_bx=#{isBx}")
    public List<Office> selfBx(long eId,int isBx);

    @Select("select off_id,item_name,item_price,item_count,item_Totalprice,purchase,e_Id,is_Bx from office where is_Bx=#{isBx}")
    public List<Office> listBx(int isBx);
}
